export function getAllIds(tree, idName) {
    let ids = [];
    for (let node of tree) {
        if (node.children && node.children.length > 0) {
            ids = ids.concat(getAllIds(node.children, idName));
        } else {
            ids.push(node[idName]);
        }

    }
    return ids;
}